package com.elastic;

import com.elastic.controller.IndexController;
import com.jfinal.config.*;
import com.jfinal.server.undertow.UndertowServer;
import com.jfinal.template.Engine;
import io.undertow.Undertow;

/**
 * @author: 李德才
 * @description:
 * @create: 2021-04-05 16:03
 **/
public class MainConfig extends JFinalConfig {
    @Override
    public void configConstant(Constants constants) {
        constants.setDevMode(true);

    }

    @Override
    public void configRoute(Routes routes) {
        routes.add("/", IndexController.class);

    }

    @Override
    public void configEngine(Engine engine) {

    }

    @Override
    public void configPlugin(Plugins plugins) {

    }

    @Override
    public void configInterceptor(Interceptors interceptors) {

    }

    @Override
    public void configHandler(Handlers handlers) {

    }

    public static void main(String[] args) {
        UndertowServer.start(MainConfig.class, 80, true);
    }
}
